<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Box</title>
  <style>
    *{
      margin: 0;
      padding: 0;
      list-style: none;
    }
    .box{
      margin: 50px auto;
      position: relative;
      width: 500px;
      height: 700px;
      border: 1px solid gray;
      font-size: 12px;
    }
    .box>div{
      width: 400px;
      height: 80px;
      border: 1px solid gray;
    }
    .box>div>div{
      width: 80px;
      height: 20px;
      /* border: 1px solid palevioletred; */
      background-color: powderblue;
    }
    .box-orient{
      /* 需要设置为webkitbox */
      display: -webkit-box;

      box-orient: horizontal;
      box-direction: normal;
    }
    .box-flex{
      display: flex;
      
    }
    .box-flex>div{
      font-size: 12px;
      /* transform: scale(.5); */
      flex: 1;
    }
    .box-flex>div:nth-child(1){
      flex: 1 1 100px;
    }
    .box-flex>div:nth-child(2){
      flex: 2 2 200px;
    }
    .box-flex>div:nth-child(3){
      flex: 3 3 300px;
    }
    
    .box-flexGrow{
      display: flex;
    }
    .box-flexGrow>div:nth-child(2){
      flex-grow: 1;
    }
    .box-flexGrow>div:nth-child(3){
      flex-grow: 3;
    }

    .box-flexShrink{
      display: flex;
    }
    .box-flexShrink>div:nth-child(1){
      width: 100px;
    }
    .box-flexShrink>div:nth-child(2){
      width: 200px;
    }
    .box-flexShrink>div:nth-child(3){
      width: 300px;
      flex-shrink: 3;
    }

    .box-flexBasis{
      display: flex;
    }
    .box-flexBasis>div:nth-child(1){
      width: 100px;
    }
    .box-flexBasis>div:nth-child(2){
      width: 200px;
    }
    .box-flexBasis>div:nth-child(3){
      width: 300px;
      flex-basis: 3;
    }

    .box-flexFlow{
      display: flex;
      /* flex-flow: column; */
      /* flex-direction: row-reverse; */
      /* align-items: flex-end; */
      justify-content: space-evenly;
    }
    .box-flexFlow>div{
      border: 1px solid gray;
    }
    .box-flexFlow>div:nth-child(1){
      order: 1;
    }
    .box-flexFlow>div:nth-child(2){
      order: 2;
    }
    .box-flexFlow>div:nth-child(3){
      order: 0;
    }
  </style>
</head>
<body>
  <div class="box">
    <div class="box-orient">
      <div></div>
      <div></div>
      <div></div>
    </div>
    <div class="box-flex">
      <div>设置或检索弹性盒</div>
      <div>模型对象的子元素</div>
      <div>如何分配空间。</div>
    </div>
    <div class="box-flexGrow">
      <div>a</div>
      <div>b分配剩</div>
      <div>c余空间</div>
    </div>
    <div class="box-flexShrink">
      <div>a设置或检索</div>
      <div>b弹性盒的</div>
      <div>c收缩比率</div>
    </div>
    <div class="box-flexBasis">
      <div>a设置或检索</div>
      <div>b弹性盒的</div>
      <div>c伸缩基准值</div>
    </div>

    <div class="box-flexFlow">
      <div>a设置或检索</div>
      <div>b弹性盒的子元</div>
      <div>c素排列方式</div>
    </div>
  </div>
</body>
</html>